/*
 * @Author: ganjiejie 8025279+ganjiejie@user.noreply.gitee.com
 * @Date: 2025-05-21 15:29:27
 * @LastEditors: ganjiejie 8025279+ganjiejie@user.noreply.gitee.com
 * @LastEditTime: 2025-05-21 16:21:07
 * @FilePath: \gj-vue3-vite-pinia-app\src\store\goods.js
 * @Description: 购物车仓库
 *
 * Copyright (c) 2025 by ${git_name_email}, All Rights Reserved.
 */
import { defineStore } from "pinia";
export const useGoodsStore = defineStore("goods", {
  state: () => ({
    goods: [
      {
        id: 1,
        name: "商品1",
        price: 10,
        content:
          "商品1的描述商品1的描述商品1的描述商品1的描述商品1的描述商品1的描述",
        img: "goods1.jpg",
      },
      {
        id: 2,
        name: "商品2",
        price: 20,
        content: "商品2的描述商品2的描述商品2商品2的描述商品2的描",
        img: "goods2.jpg",
      },
      {
        id: 3,
        name: "商品3",
        price: 30,
        content: "商品3的描述商品3的描述商品商品3的描述商品3的描述商",
        img: "goods3.jpg",
      },
    ],
  }),
  getters: {
    getGoods: (state) => state.goods,
  },
  actions: {},
});
